#
#  TCP test Makefile
#

SHELL = /bin/sh


#----------------------------------------------------------- SETUP

TOPDIR = ../../../../../..
include $(TOPDIR)/Makefile.common

JAVAC = javac -O -classpath $(SSFNET_TEST_CLASSPATH)
JAVA  = java  -classpath ../..:$(SSFNET_TEST_CLASSPATH)
JAVARST  = java  -classpath .:../..:$(SSFNET_TEST_CLASSPATH)

all:    contimer srvrej rst
rst:
	$(JAVAC) *.java
	$(JAVARST)  SSF.Net.Net 100 $(TOPDIR)/examples/net.dml rst.dml > rst.log 2>&1
	$(JAVA) SSF.OS.DumpPro rst.tcpdump > rst.tcpdump.txt 2>&1
	@echo ''
	@echo '----CONN ABORT RESET TEST: COMPLETED (see rst.log, rst.tcpdump.txt)----'
	@echo ''

srvrej:
	$(JAVA)  SSF.Net.Net 100 $(TOPDIR)/examples/net.dml srvrej.dml > srvrej.log 2>&1
	$(JAVA) SSF.OS.DumpPro srvrej.tcpdump > srvrej.tcpdump.txt 2>&1
	@echo ''
	@echo '----CONN RESET TEST: COMPLETED (see srvrej.log, srvrej.tcpdump.txt)----'
	@echo ''

contimer:
	$(JAVA)  SSF.Net.Net 1000 $(TOPDIR)/examples/net.dml contimer.dml > contimer.log 2>&1
	$(JAVA) SSF.OS.DumpPro contimer.tcpdump > contimer.tcpdump.txt 2>&1
	@echo ''
	@echo '---CONNECTION TIMER TEST: COMPLETED (see contimer.log, contimer.tcpdump.txt)---'
	@echo ''
	
clean:
	rm -f *.log
	rm -f *.tcpdump
	rm -f *.txt
	rm -f *.class


